<template>
  <div class="wall-contain">
    <el-header style="font-size: 20px; font-weight: bold">
      <i class="el-icon-s-platform" style="margin-right: 15px"></i>
      <span>绵羊墙{{status}}</span>
    </el-header>

    <el-table :data="sheeps" border style="width: 100%">
      <el-table-column prop="id" label="序号" width="50"></el-table-column>
      <el-table-column prop="sheep_name" label="厂商" ></el-table-column>
      <el-table-column prop="sheep_username" label="账户"></el-table-column>
      <el-table-column prop="sheep_password" label="初始或常用密码"></el-table-column>
    </el-table>
  </div>
</template>

<script>
import axios from 'axios'
export default {
  data() {
    return {
      sheeps: [],
      status: '',
    }
  },
  mounted(){
    const url = 'http://localhost:5000/wall'
    axios.get(url).then(response => {
        const result = response.data
        this.sheeps = result.sheeps
        this.status = result.status
   })
  },
  methods: {
  },
}
</script>

<style lang="scss" scoped>
.el-header {
  background-color: rgba(51, 48, 51, 0.219);
  color: #333;
  line-height: 60px;
}

.wall-contain {
  border: 1px solid rgba(0, 0, 0, 0);
  box-shadow: 0px 0px 12px 0 rgba(0, 0, 0, 0.1);
  margin: 5px;
}
</style>
